<!DOCTYPE HTML>
<html>
<head>
    <meta charset="utf-8">
    <meta name="renderer" content="webkit|ie-comp|ie-stand">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no" />
    <meta http-equiv="Cache-Control" content="no-siteapp" />
    <link rel="stylesheet" type="text/css" href="__CSS__/main.css" />
    <link rel="stylesheet" type="text/css" href="__CSS__/common.css" />
    <link rel="stylesheet" type="text/css" href="__CSS__/bootstrap.min.css" />
    <script type="text/javascript" src="__EXTEND__/lib/jquery/1.9.1/jquery.min.js"></script>
    <script type="text/javascript" src="__EXTEND__/js/bootstrap.min.js"></script>
    <script type="text/javascript" src="__EXTEND__/lib/layer/2.4/layer.js"></script>
    <![endif]-->
    <title></title>
</head>
<body>
<div class="contant">
<div class="row">
        <div class="top">行政人事部>银行合同送回</div>
        <div class="content applylist">
            <div class="box">
                <h1>银行合同送回</h1>
                <div class="list-block">
                    <div class="row">
                    <form action='' class="form-inline text-right m-b-5 fr">
                        <label>用户名称:</label> <input type="text" name="user_name" placeholder="请输入姓名" value={$_GET['user_name']} >
                        <label>身份证号:</label> <input type="text" name="identity_no" placeholder="请输入身份证号" value={$_GET['identity_no']} >
                        <label>部门:</label> <input type="text" name="department_name" placeholder="部门名" value={$_GET['department_name']}>
                        <button class="search" type="submit"><img src="__IMG__/search.png" alt="">查询</button>
                    </form>
                    </div>
                    <div class="row">
                        <table class="list">
                        <thead>
                            <tr>
                                <th class="row-selected row-selected"><input type="checkbox" id="selectall" value="1" /></th>
                                <th>编号</th>
                                 <th>申请人</th>
                                 <th>身份证号</th>
                                 <th>手机号</th>
                                 <th>业务部门</th>
                                 <th>申请时间</th>
                                 <th>状态</th>
                                 <th>进入当前状态时间</th>
                                 <!-- <th>审核状态</th> -->
                                 <th>银行</th>
                                 <th>操作</th>
                            </tr>
                            </thead>
                            <tbody class="tbody thmb">
                            <volist name="list" id="user">
                                <tr >
                                    <td><span class="ckbox"><input class="ids" type="checkbox" name="id[]" value="{$user.id}"/></span></td>
                                    <td>{$user.entry_no}</td>
                                    <td>{$user.user_name}</td>
                                    <td>{$user.identity_no}</td>
                                    <td>{$user.telephone}</td>
                                    <td>{$user.department_name}</td>
                                    <td>{$user.create_time|date='Y-m-d H:i:s', ###}</td>
                                    <td>贷款合同已接收</td>
                                    <td>{$user.update_time|date='Y-m-d H:i:s', ###}</td>
                                    <td>{$user.bank_short_name}</td>
                                    <td><a href="{:U('Contract/set_status', array('id' => $user['id'],'status'=>16))}">送回</a></td>
                                </tr>
                            </volist>
                          </tbody>
                        </table>
                        <div class="clearfix">
                            <button class="actBtn btn btn-default btn_50"" data-id='{$list.id}' data-toggle="modal" data-act='1' data-target='#myModal' type="button">寄出</button>
                            <button class="actBtn btn btn-default btn_50"" data-id='{$list.id}' data-toggle="modal" data-act='2' data-target='#myModal' type="button">接收人</button>
                        </div>
                    </div>
                    {$page}
                </div>
            </div>
        </div>
    </div>
        <!-- 模态框 start -->
<div id="myModal" class="modal fade in" style="display: none;">
    <div class="modal-dialog modal-lg" style='width:720px;'>
        <!--  -->
            <div class="modal-content" style="padding-bottom:0px;">
                <div class="modal-header">
                    <button type="button" class="close" data-dismiss="modal">&times;</button>
                    <h4 class="modal-title">数据加载中……</h4>
                </div>
                <div class="modal-body" style='height:400px;overflow-y:auto;'>数据加载中……</div>
                <div class="modal-footer" style="margin-top:0px;">
                    <button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
                </div>
            </div>
        </div>
</div>
    <!-- 模态框 end -->
     <div class="express hide">
                <h1>快递录入<span>(标*为必填项)</span></h1>
                <div class="list-block">
                    <div class="row">
                        <label>寄件人:</label>
                        <input type="text" name="send_name" value=''>
                        <label>收件人:</label>
                        <input type="text" name="addressee" value=''>
                    </div>
                    <div class="row">
                        <label>快递单号:</label>
                        <input type="text" name="express_number" value=''>
                       <!--  <label>客户姓名:</label>
                        <input type="text" name="user_name" value='{$user.user_name}'> -->
                    </div>
                    <div class="row">
                        <label>快递内容(文件名):</label>
                        <textarea name="express_content" id="" cols="60" rows="5"></textarea>
                    </div>
                    <div class="row">
                        <label>快递时间:</label>
                        <input type="date" name="express_times" placeholder="请选择时间" value="{:date('Y-m-d')}" />
                       <!--  <input type="text" id="express_times" name="express_times" value="{:date('Y-m-d')}" class="datepicker" readonly /> -->
                        <!-- <input type="text" name="express_time"> -->
                        <label>快递公司:</label>
                        <select name="company_id" id="form-field-10">
                            <foreach name="express_company" item="v" >
                             <if condition="$key eq $info['company_id']">
                            <option value={$key} selected>{$v}</option>
                             <else />
                             <option value={$key}>{$v}</option>
                            </if>
                            </foreach>
                        </select>
                    </div>
                    <input name='act' value='1' type='hidden'/>
          </div>
     </div>
          <div class="shou hide">
                <h1>合同接收</h1>
                <div class="list-block">
                    <div class="row">
                        <label>收件人:</label>
                        <input type="text" name="addressee" value=''>
                    </div>
                    <input name='act' value='2' type='hidden'/>
            </div>
        </div>
</div>


    <script type="text/javascript" src='{:COM}js/daterangepicker.min.js'></script>
    <script src="{:COM}js/ajaxfileupload.js"></script>
   <script type="text/javascript">
   $('input.datepicker').datetimepicker({format : "yyyy-mm-dd", minView : 2, autoclose : true});
             $('#selectall').click(function(){
                if($(this).is(':checked')) {
                    $('.thmb').each(function(){
                        $(this).find('input').attr('checked',true);
                    });
                } else {
                    $('.thmb').each(function(){
                        $(this).find('input').attr('checked',false);
                    });
                }
            });
            $('.ckbox').click(function(){$('#selectall').attr('checked',false);});
            $('.actBtn').click(function(){
                var act = $(this).data('act'), id = $(this).data('id'), html = '', title = '', ids = '0';;
                $.each($('.ids:checked'), function(i, v){ids += ',' + $(v).val();});
                   if(ids == '0'){
                        alert('请勾选需要操作的会员！');
                    }else{
                            html += '<div class="com_form"><form action="{:U("Express/Contract")}" method="post" id="baseForm" class="wid_100"><div class="basics"><input type="hidden" name="ids" value="'+ids+'" />';
                            if(act == 1){
                                title = '寄出快递';
                                html += $('.express').html();
                            }else if(act == 2){
                                title = '接收详情';
                                html += $('.shou').html();
                            }
                          html += '<div class="group clearfix"><label class="title wid_30 fl"></label><div class="fill wid_70 fl"><button type="submit" class="btn btn_yellow btn_100">保存</button></div></div></div></form></div>';
                          $('.modal-body').html(html);
                    }
               $('.modal-title').html(title);
            });
             $('.uploadA').change(function(){
            $.ajaxFileUpload({
                url:'{:U("Upload/logo")}',//处理图片脚本
                secureuri: false,
                fileElementId :'fileId1',//file控件id
                dataType : 'text',
                success: function (data){
                    $("#fristImg").attr("src",data);
                    $("#one").attr("value",data);
                },
                error: function(data){
                    alert(data+"333");
                }
            })
        })
</script>
</body>
</html>
